AngouriMath
AngouriMath.Convenience.Setting`1
Classes within the AngouriMath.Convenience.Setting`1 namespace
AutoBackRollableTemporarySettingUnit
Summary
This tiny struct is needed to be under `using` operator, so that your settings
are automatically rolled back on the end of your method
using var _ = MathS.Settings.SomeSetting.Set(4); // do something, once the method is ended, the setting is automatically returned to the initial statementFrame
Summary
One pushed value, and the chain below it. Never mutated once built.
Remarks
Id is what a scope is released by, rather than the frame's own
reference. Releasing a scope that is not on top rebuilds everything above it, and
a rebuilt frame is a different object — so identifying a scope by its frame would
leave the ones above it impossible to release afterwards. The id is a counter and
not a Guid: generating a guid per scope cost more than everything
else Set(`0) does put together.
Angouri © 2019-2023 · Project's repo · Site's repo · Octicons · Transparency · 1953 pages online